package com.aspose.cells;

class zcef extends zcdb {
   zcef() {
      this.d = 153;
   }

   void a(Workbook var1) throws Exception {
      boolean var2 = false;
      boolean var3 = false;
      int var6;
      if (var1.b != null) {
         zpd var4 = var1.b.i;
         if (var4.d != null) {
            var6 = zase.C(var4.d);
         } else {
            var6 = 124226;
         }

         if (var4.e) {
            var3 = true;
         }
      } else {
         var6 = 124226;
      }

      byte var7 = 8;
      int var8;
      if (var1.getWorksheets().h() == null) {
         var8 = var7 + 4;
      } else {
         var8 = var7 + 4 + var1.getWorksheets().h().length() * 2;
      }

      this.c = new byte[var8];
      this.c[0] = 32;
      if (var1.getSettings().getDate1904()) {
         this.c[0] = (byte)(this.c[0] | 1);
      }

      if (var1.getSettings().getRemovePersonalInformation()) {
         this.c[0] = (byte)(this.c[0] | 8);
      }

      if (var1.getSettings().getHidePivotFieldList()) {
         this.c[1] = (byte)(this.c[1] | 4);
      }

      if (var3) {
         this.c[1] = (byte)(this.c[1] | 8);
      }

      switch(var1.getSettings().getUpdateLinksType()) {
      case 1:
         this.c[1] = 1;
         break;
      case 2:
         this.c[1] = 2;
      }

      this.c[2] = 1;
      System.arraycopy(com.aspose.cells.b.a.zc.a(var6), 0, this.c, 4, 4);
      if (var1.getWorksheets().h() != null) {
         byte var5 = 8;
         zcch.a(this.c, var5, var1.getWorksheets().h());
      }

   }
}
